#include<stdio.h>


//1,2,3,4,
int func(int number)
{
	if (number > 9)
	{
		func(number / 10);
	}
	printf("%d ",number % 10);
}
int main()
{
	func(374027);
	return 0;
}